/**
 * Copyright (C), 2018 store
 * Encoding: UTF-8
 * Date: 19-10-25 上午10:51
 * History:
 */
package com.swak.frame.common;

import java.util.Objects;

/**
 * CodeEnum.java
 * 
 * @author ColleyMa
 * @version 19-10-25 上午10:51
 */
public interface CodeEnum {

    public Integer getCode();

    public String getName();

    default public boolean eq(String code) {
        return Objects.equals(code, String.valueOf(this.getCode()));
    }

    default public boolean eq(Integer code) {
        return Objects.equals(code, this.getCode());
    }
}
